home *** CD-ROM | disk | FTP | other *** search
/ C!T ROM 3 / ct-rom iiib.zip / ct-rom iiib / OS2 / PROGRAM / LB05 / TREKEXP.BAS < prev    next >
BASIC Source File  |  1994-03-05  |  2KB  |  74 lines

  1.  
  2.  
  3.     'open a graphical window and display startrek ships
  4.  
  5.     drawX = 40
  6.     drawY = 40
  7.  
  8.     WindowWidth = 300
  9.     WindowHeight = 300
  10.     open "TREK SHIPS" for graphics as #1
  11.     print #1, "fill black"
  12.     print #1, "color white"
  13.  
  14.     'print #1, "home ; down ; size 51 ; circle 25"
  15.     'print #1, "size 10 ; circle 45"
  16.  
  17.     for x = 0 to 342 step 54
  18.             print #1, "home"
  19.             angle = x
  20.            print #1, "north; up; turn "; angle; "; go 100; down"
  21.            print #1, "posxy"
  22.            input #1, drawX, drawY
  23.              gosub [Enterprise]
  24.     next x
  25.  
  26.  
  27.     print #1, "home"
  28.  
  29.     'for x = 22 to 50 step 5
  30.     '    print #1, "size "; 53-x; " ; circle "; x
  31.   '  next x
  32.  
  33.     'print #1, "size 10 ; circle 3"
  34.     'print #1, "size 5 ; circle 10"
  35.     'print #1, "size 4 ; circle 14"
  36.     'print #1, "size 3 ; circle 16"
  37.     'print #1, "size 1 ; circle 18"
  38.  
  39.  
  40.     input r$
  41.  
  42.  end
  43.  
  44.  
  45. [Enterprise]
  46.  
  47.     print #1, "color white"
  48.     print #1, "place "; drawX; " "; drawY
  49.     print #1, "north; turn "; angle; "; down; turn 280; go 8; turn 80; go 9; turn 180; size 2; go 15"
  50.     print #1, "size 1"
  51.     print #1, "place "; drawX; " "; drawY
  52.     print #1, "north; turn "; angle; "; turn 80; go 8; turn 280; go 9; turn 180; size 2; go 15"
  53.     print #1, "size 1"
  54.     print #1, "place "; drawX; " "; drawY
  55.     print #1, "north; turn "; angle; "; go 3 ; turn 180; size 2; go 14"
  56.     size =45
  57.     gosub [drawCircle]
  58.     print #1, "flush"
  59.  
  60.     print #1, "size 1"
  61.  
  62.     return
  63.  
  64.  
  65.  
  66. [drawCircle]
  67.  
  68.     print #1, "size "; size + 1; " ; circle "; int(size / 2)
  69.     print #1, "size "; int(size / 5) + 1; " ; circle "; int(size * 0.9)+1
  70. return
  71.  
  72.     print #1, "home ; down ; size 51 ; circle 25"
  73.     print #1, "size 10 ; circle 45"
  74.